

<!--[if lte IE 7]>
<script type="text/javascript" src="js/jquery/jquery.js"></script>
<script type="text/javascript" src="js/jquery/jquery.dropdown.js"></script>
<![endif]-->

<?php $this->beginContent('//layouts/main'); ?>
<div class="span-19" id="contentLeft">
<div id="content">
	<?php echo $content; ?>
</div><!-- content -->
</div>
<div class="span-5 last" id="contentRight">
	<div id="sidebar">
            <?php
                $people = array();
                $autori = Autore::model()->findAll();
                foreach($autori as $autore)
                {
                    $people[] = array('label'=>$autore->nome, 'url'=>array('autore/view', 'id'=>$autore->id));
                }
                $categorie = Categoria::model()->findAll();
                $works = array();
                foreach($categorie as $categoria)
                {
                    $works[] = array('label'=>$categoria->title, 'url'=>array('categoria/view', 'id'=>$categoria->id));
                }
                $menu = array();
                $menu[] = array('label'=>'PEOPLE','url'=>array('autore/index'),'items' => $people);
                $menu[] = array('label'=>'WORKS','url'=>array('categoria/index'),'items' => $works);
                $menu[] = array('label'=>'FRIENDS','url'=>array('site/index'),'items' => 
                    array(
                        array('label'=>'White Mosquito','url'=>'http://www.whitemosquito.it'),
                        array('label'=>'Mastercastle','url'=>'http://www.myspace.com/mastercastle'),
                        array('label'=>'Athlantis','url'=>'http://www.athlantis.net/'),
                    ));
		$menu[] = array('label'=>'STUFF <img src="images/zed.jpg" width="15"/>','url'=>array('site/index'));
		$this->widget('ext.emenu.EMenu', array(
			'items'=>$menu,
                        'vertical'=>true,
                        'rtl'=>true,
                    'encodeLabel'=>false,
                        
			
		));
		
                /*
                $this->beginWidget('zii.widgets.CPortlet', array(
			'title'=>'CATEGORIE',
		));
		$this->widget('zii.widgets.CMenu', array(
			'items'=>$this->categories,
			'htmlOptions'=>array('class'=>'operations'),
		));
		$this->endWidget();
                
                $this->beginWidget('zii.widgets.CPortlet', array(
			'title'=>'FRIENDS',
		));
		$this->widget('zii.widgets.CMenu', array(
			'items'=>$this->friends,
			'htmlOptions'=>array('class'=>'operations'),
		));
		$this->endWidget();
                
                $this->beginWidget('zii.widgets.CPortlet', array(
			'title'=>'STUFF',
		));
		$this->widget('zii.widgets.CMenu', array(
			'items'=>$this->stuff,
			'htmlOptions'=>array('class'=>'operations'),
		));
		$this->endWidget();*/
	?>
	</div><!-- sidebar -->
</div>
<?php $this->endContent(); ?>